const Router = require('koa-router')
const { User } = require('../../models/user')
const { Auth } = require('../../core/middleware/auth')
const router = new Router({
    prefix: '/v1/user',
})
router.get('/getUserInfo', new Auth().m, async (ctx, next) => {
    //邮箱,密码,确认密码,昵称
    const res = await User.getUserByUserUserId(ctx.auth.id)
    ctx.body = {
        key: '成功',
        data: res
    }
})
module.exports = router
